package com.suning.sawp.service.impl.dao;

import java.util.Date;
import java.util.HashMap;
import java.util.Map;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.suning.framework.dal.client.DalClient;
import com.suning.sawp.intf.dao.UnDealBiFileLogDaoService;
import com.suning.sawp.po.bi.UnDealBiFileLog;

@Service("unDealBiFileLogDaoService")
public class UnDealBiFileLogDaoServiceImpl implements UnDealBiFileLogDaoService {

    @Resource
    DalClient dalClient;
    
    @Override
    public void addUnDealBiFileLog(UnDealBiFileLog unDealBiFileLog) {
        dalClient.persist(unDealBiFileLog);
    }

    @Override
    public void updateLogStatus(Long id, String status) {
        Map<String, Object> paramMap = new HashMap<String, Object>();
        paramMap.put("id", id);
        paramMap.put("status", status);
        paramMap.put("updateTime", new Date());
        dalClient.execute("BI_DEAL_EXCEPTION.UN_DEAL_LOG_U_STATUS", paramMap);
    }

}
